Audioreactive bugfix: auto-suspend in all realtime modes, but stay active when "Use main segment only"#5599
Conversation
* Modernize auto-suspend condition - DDP, DMX and TPM2NET were missing (thanks @blazoncek for the hint)
WiFiUDP.flush() -> WiFiUDP.clear()
This comment was marked as duplicate.
This comment was marked as duplicate.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
WalkthroughUpdated ChangesAudioreactive UDP Buffer Management and Realtime Mode Gating
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested labels
Suggested reviewers
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
|
The code for handling The only benefit (I see) is to notify UI (and even in this scenario there is already There are also a other bugs related to current use of If you want to keep |
@blazoncek to be honest with you, this comment does not make much sense to me. You know who designed AR and where it comes from. I still doubt that you have the necessary understanding to instruct me how AR should be coded. If you know about real bugs, please do what everybody else does - open a ticket with a step-by-step scenario, screenshots etc. Then we can discuss. The style you show here is not helpful at all. In February 2026 you told me clearly (in another issue discussion) that we should not even ask you for anything related to WLED -"live with that" were your own words. |
|
I am sorry. You will not hear from me any more. |
explain rationale behind one line that differs from 8266 code. The initial "unlock" ensures that FFT_Task can initialize even when in sound receive mode -> might cause some RAM allocation even when not strictly needed, but also ensures a clean start-up of audio processing.
| } | ||
| micDataReal = 0.0f; // just to be sure | ||
| if (enabled) disableSoundProcessing = false; | ||
| if (enabled) disableSoundProcessing = false; // allows FFT_Task to run at least once, even when loop() might disable again |
There was a problem hiding this comment.
PS: this is safe even with "init == true" => init leads to vTaskSuspend(FFT_Task) so no FFT can run during OTA.
|
tested, works as expected. |
…tive when "Use main segment only" (#5599) * fixes a minor problem with newer realtime modes (DDP, TPM2NET and DMX) not causing auto-suspend of sound processing. * ensure that AR audio stays active when "Use main segment only" (other segments are still controlled locally) * small update for better compatibility with V5 builds
NB: the impact on users is minimal, especially on esp32 and esp32-s3 - audioreactive FFT does not use much CPU time on these boards (less than 20%). Any way the fix can be applied to 16.0.0, 17.0.0 and 0.15.5 in the same way.
Summary by CodeRabbit